Skip to content

Conversation

AhmedMagedC
Copy link
Contributor

Resolves #1104

Changes

  • breaks the Preferences class into two classes: app.utils.Preferences and app.Preferences
  • app.utils.Preferences class is the stand-alone version making the loading and saving of preferences independent
  • app.Preferences depends on app.utils.Preferences for the main functionalties (loading, saving, getting a value) but also adds other app dependent functionalties (fonts, language, ...)
  • gracefully handles exceptions by adding a centralized custom Exception: PreferencesException
  • loading of default.txt is now via JAR resource system

Todo

  • the SettingFolder location depends on the Base class, which forces you to explicitly set the location when using app.utils.Preferences. We can decouple it from Base class making it independt of app module
  • Adding callback events/listeners when a preference changes
  • Tests that will declare and test the functionality of Preferences
  • A Github Action that will run the Tests on all supported platforms

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Making Preferences standalone
1 participant